<div nz-row class="mb30">
  <button nz-button nzType="primary" nzSize="large" nzShape="circle" (click)="add()">
    <i nz-icon nzType="plus" nzTheme="outline"></i>
  </button>
</div>
<div nz-row>
  <nz-card [nzBordered]="false" nzTitle="项目列表">
    <nz-table #basicTable [nzData]="list"
              [nzShowPagination]="false"
              [nzLoading]="loadingFlag"
    >
      <thead>
      <tr>
        <th>名称</th>
        <th>服务器数量</th>
        <th>创建时间</th>
        <th>操作</th>
      </tr>
      </thead>
      <tbody>
      <tr *ngFor="let data of basicTable.data">
        <td>
          <a [routerLink]="'/project/detail/'+data.id">{{ data.name }}</a>
        </td>
        <td>{{ data.serverList.length || 0 }}</td>
        <td>{{ data.createAt | date:'yyyy-MM-dd HH:mm' }}</td>
        <td>
          <a (click)="delete(data.id)">删除</a>
        </td>
      </tr>
      </tbody>
    </nz-table>
  </nz-card>
</div>
<nz-row>
  <nz-pagination class="float-right" [nzHideOnSinglePage]="true"
                 [nzPageIndex]="param.pageNo" [nzTotal]="param.count" [nzPageSize]="param.pageSize" nzSimple
                 (nzPageIndexChange)="pageChange($event)"
  ></nz-pagination>
</nz-row>


<nz-modal [(nzVisible)]="isVisible" nzTitle="请确认" (nzOnCancel)="isVisible = false" (nzOnOk)="okCallback()"
          [nzOkLoading]="okLoading">
  <p>确认要删除吗？</p>
</nz-modal>
